home *** CD-ROM | disk | FTP | other *** search
/ Mac-Source 1994 July / Mac-Source_July_1994.iso / C and C++ / Commun⁄Network / RevRdist Folder / RevRdist / headers / Bullet Field Mgr.h next >
Encoding:
C/C++ Source or Header  |  1992-01-26  |  2.6 KB  |  79 lines  |  [TEXT/KAHL]

  1. #ifndef _BulletFieldMgr_
  2. #define _BulletFieldMgr_
  3.  
  4.  
  5. int        BulletFieldCreate(DialogPtr Dialog, int NumItems, int FieldCount, int Field1, ...);
  6. void    BulletFieldDispose(DialogPtr Dialog);
  7.  
  8.  
  9.  
  10.  
  11. /*    ——————————————————————————————————————————————————————————————————
  12.     Bullet Field Manager -- Procedure Summary
  13.     ——————————————————————————————————————————————————————————————————
  14.     
  15.     •    BulletFieldCreate
  16.     •    BulletFieldDispose
  17.     
  18.     
  19.     
  20.     BulletFieldCreate
  21.     —————————————————
  22.     
  23.     int BulletFieldCreate(DialogPtr Dialog, int NumItems, int FieldCount, 
  24.         int Field1, ...);
  25.     
  26.     BulletFieldCreate sets-up one or more bulleted fields in the dialog 
  27.     specified by Dialog.  The fields to be bulleted are specified by a 
  28.     variable number of arguments beginning with Field1 - it and all 
  29.     following parameters should be the numbers of items in the dialog
  30.     item list that are to be bulleted.  FieldCount should be the
  31.     number of items to be bulleted, i.e. the total number of parameters 
  32.     beginning with Field1 and including all following parameters.  The 
  33.     value in NumItems is added to each of the item numbers specified 
  34.     in Field1 (and all following) parameters.  This is handy when 
  35.     writing cdevs, but will be of no use in conventional dialogs; just 
  36.     set it to zero in cases where you don't need it.
  37.     
  38.     In order to setup a single bulleted field in item 7 of a dialog 
  39.     you've created which is pointed to by a variable named MyDialog, 
  40.     you'd invoke BulletFieldCreate in the following manner:
  41.     
  42.     BulletFieldCreate(MyDialog, 0, 1, 7);
  43.     
  44.     If, instead, you wanted to setup two bulleted fields in items 7 and 
  45.     13 in that same dialog, you'd make the call this way:
  46.     
  47.     BulletFieldCreate(MyDialog, 0, 2, 7, 13);
  48.     
  49.     Note that FieldCount (the third parameter) is now 2, because two
  50.     dialog item numbers follow it in the parameter list.
  51.     
  52.     BulletFieldCreate returns TRUE if it successfully sets-up the 
  53.     requested bulleted fields.  If it fails for some reason, it will
  54.     return FALSE.
  55.     
  56.     WARNING:  The Bullet Field Manager uses the refCon field of the
  57.               dialog window to store a pointer to its internal data.
  58.               If you use the refCon field for other purposes, you'll
  59.               need to modify all references (there's only 3 of them)
  60.               to the refCon field in the "Bullet Field Mgr.c" file 
  61.               in order to allow for your usage.
  62.     
  63.     
  64.     
  65.     BulletFieldDispose
  66.     ——————————————————
  67.     
  68.     void BulletFieldDispose(DialogPtr Dialog);
  69.     
  70.     BulletFieldDispose reverses the effects of BulletFieldCreate, and
  71.     deallocates all the storage it allocated.  Call BulletFieldDispose
  72.     just before disposing of the dialog itself.
  73.     
  74.     
  75.     
  76.     ——————————————————————————————————————————————————————————————————    */
  77.  
  78.  
  79. #endif